import { defineStore } from 'pinia';
import { getChildPartsList } from 'src/services/partsService';

import {  ChildStockItem } from 'src/services/type';
export const usePartsChildMapStore = defineStore('usePartsChildMapStore', {
  state: () => ({
    itemList: itemList,
  }),
  getters: {},
  actions: {
    async getChildPartsData(parent_part_stock_code:string,parent_serial_no:string){
      console.log(parent_part_stock_code);
      
      const res = await getChildPartsList(parent_part_stock_code, parent_serial_no)
      if(res.data){
        console.log(res.data);
        
      }
    }
  },
});

const itemList: ChildStockItem[] =[]
